package com.gitee.qdbp.base.system.service;

import java.util.List;
import com.gitee.qdbp.base.system.model.IAccountType;

/**
 * 默认值配置
 *
 * @author zhaohuihua
 * @version 170719
 */
public class DefaultValueConfig implements IDefaultValueConfig {

    private UserTypeConverter<?> userTypeConverter;

    public DefaultValueConfig(UserTypeConverter<?> userTypeConverter) {
        this.userTypeConverter = userTypeConverter;
    }

    private String tenantCode;

    @Override
    public String getTenantCode() {
        return tenantCode;
    }

    public void setTenantCode(String tenantCode) {
        this.tenantCode = tenantCode;
    }

    @Override
    public IAccountType getUserType() {
        return userTypeConverter.getDefaults();
    }

    @Override
    public List<IAccountType> getUserTypeChoose() {
        return userTypeConverter.getChoose();
    }

    @Override
    public Class<? extends Enum<?>> getUserTypeClass() {
        return userTypeConverter.getEnumType();
    }

}
